package com.gitee.qdbp.able.jdbc.model;

import java.io.Serializable;

/**
 * Like Escape
 *
 * @author zhaohuihua
 * @version 20201111
 */
public class LikeValue implements Serializable {

    /** serialVersionUID **/
    private static final long serialVersionUID = 1L;
    /** 转义字符 **/
    private final char escapeChar;
    /** 包含特殊字符匹配的模式字符串: _匹配一个字符, %匹配零个或多个字符 **/
    private final String patternString;

    public LikeValue(String patternString) {
        this.escapeChar = 0;
        this.patternString = patternString;
    }

    public LikeValue(char escapeChar, String patternString) {
        this.escapeChar = escapeChar;
        this.patternString = patternString;
    }

    /** 转义字符 **/
    public char getEscapeChar() {
        return escapeChar;
    }

    /** 包含特殊字符匹配的模式字符串: _匹配一个字符, %匹配零个或多个字符 **/
    public String getPatternString() {
        return patternString;
    }

}
